<?php
if (!isset($model))
    $model = new UserLogin();

$this->pageTitle = Yii::app()->name . ' - ' . Yii::t("UserModule.user", "Login");
//$this->breadcrumbs=array(
//	Yii::t("UserModule.user", "Login"),
//);
?>

<!--<h1> <?php // echo Yii::t("UserModule.user", "Login");       ?> </h1>-->

<?php if (Yii::app()->user->hasFlash('loginMessage')): ?>

    <div class="success">
        <?php echo Yii::app()->user->getFlash('loginMessage'); ?>
    </div>

<?php endif; ?>
<!--
<p>
<?php
//echo Yii::t("UserModule.user",
//		"Please fill out the following form with your login credentials:"); 
?></p>-->
<div class="login_bg" style=" margin-left: 396px;margin-top: 58px;">
    <div class="form" id="login_-form" style="text-align: center;vertical-align: top; padding:0px !important;margin: 0px !important;padding-right: 44px!important;">
        <?php echo CHtml::beginForm(); ?>

        <?php echo CHtml::errorSummary($model); ?>

        <div class="row" style="float: none !important;">
            <?php echo CHtml::activeTextField($model, 'username', array('value' => 'username', 'class' => "inputtext", "onfocus" => "javascript:if(this.value=='username'){this.value=''}", "onblur" => "javascript:if(this.value==''){this.value='username'}")) ?>
        </div>

        <div class="row" style="float: none !important;">
            <?php echo CHtml::activePasswordField($model, 'password', array('value' => 'Password', 'class' => "inputtext", "onfocus" => "javascript:if(this.value=='Password'){this.value=''}", "onblur" => "javascript:if(this.value==''){this.value='Password'}")) ?>
        </div>


        <div class="row login_button" style="float: none !important;">
            <?php echo CHtml::submitButton(Yii::t("UserModule.user", "Login "), array("class" => "btn")); ?>

        </div>




        <div class="row" style="margin-top: 34px;float: none !important;">
            <p class="hint" >
                <?php
                printf("%s", CHtml::link(Yii::t("UserModule.user", "Forgot Password?"), $this->module->recoveryUrl));
                ?>

            </p>

        </div> 

        <div class="row">
            <p class="hint">&nbsp;</p>

        </div>

       

        <!--    <div class="row">
        
            </div>-->
        <?php echo CHtml::endForm(); ?>
    </div><!-- form -->
</div>

<?php
$form = new CForm(array(
            'elements' => array(
                'username' => array(
                    'type' => 'text',
                    'maxlength' => 32,
                ),
                'password' => array(
                    'type' => 'password',
                    'maxlength' => 32,
                ),
                'rememberMe' => array(
                    'type' => 'checkbox',
                )
            ),
            'buttons' => array(
                'login' => array(
                    'type' => 'submit',
                    'label' => 'Login',
                ),
            ),
                ), $model);
?>
<script>
    $(document).ready(function() {
        $(".assist").hide();
        $(".last").hide();
      
    });

</script>
